{include file="common/_meta" /}
<title>修改留言</title>
<meta name="keywords" content="李志立，lizhilimaster@163.com">
<meta name="description" content="李志立，lizhilimaster@163.com">
</head>
<body>
	<article class="page-container">
		<form action="" method="post" class="form form-horizontal" id="form-member-add">
			<input type="hidden" name="id" id="id" value="{$data.id}" />
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>标题：</label>
				<div class="formControls col-xs-8 col-sm-9">
					<input type="text" class="input-text" disabled="disabled" name=""  value="{$data.title}" />
				</div>
			</div>
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>姓名：</label>
				<div class="formControls col-xs-8 col-sm-9 skin-minimal">
					<input type="text" class="input-text" disabled="disabled" name=""  value="{$data.name}" />
				</div>
			</div>
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>手机：</label>
				<div class="formControls col-xs-8 col-sm-9">
					<input type="text" class="input-text" disabled="disabled" name=""  value="{$data.phone}" />
				</div>
			</div>
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>时间：</label>
				<div class="formControls col-xs-8 col-sm-9">
					<input type="text" class="input-text" disabled="disabled" name="" value="{$data.create_time|date='Y-m-d H:i:s'}" />
				</div>
			</div>

			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3">当前状态：</label>
				<div class="formControls col-xs-8 col-sm-9">
					{switch name="data.isopen" }
					{case value="1"}<input class="btn btn-success-outline size-MINI radius" type="button" value="已查看">{/case}
					{case value="0"}<input class="btn  btn-danger-outline size-MINI radius" type="button" value="未查看">{/case}
					{/switch}
				</div>
			</div>
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3">修改状态：</label>
				<div class="formControls col-xs-8 col-sm-9  skin-minimal">
					<div class="radio-box">
						<input name="isopen" type="radio" id="sex-1" value="1" {if condition="$data.isopen == 1" } checked {/if}> <label
						 for="sex-1">已经查看</label>
					</div>
					<div class="radio-box">
						<input type="radio" id="sex-2" value="0" name="isopen" {if condition="$data.isopen == 0" } checked {/if}> <label
						 for="sex-2">以后处理</label>
					</div>
				</div>
			</div>
			<div class="row cl">
				<label class="form-label col-xs-4 col-sm-3">详细内容：</label>
				<div class="formControls col-xs-8 col-sm-9">
					<textarea disabled="disabled" cols="" rows="" id="desc" class="textarea" placeholder="说点什么...">{$data.neirong}</textarea>
				</div>
			</div>
			<div class="row cl">
				<div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
					<input class="btn btn-primary radius" type="submit" value="&nbsp;&nbsp;提交&nbsp;&nbsp;">
				</div>
			</div>
		</form>
	</article>
	{include file="common/_footer" /}
	<script type="text/javascript" src="__MANAGE__lib/jquery.validation/1.14.0/jquery.validate.js"></script>
	<script type="text/javascript" src="__MANAGE__lib/jquery.validation/1.14.0/validate-methods.js"></script>
	<script type="text/javascript" src="__MANAGE__lib/jquery.validation/1.14.0/messages_zh.js"></script>
	<script type="text/javascript">
		$(function() {
			$('.skin-minimal input').iCheck({
				checkboxClass: 'icheckbox-blue',
				radioClass: 'iradio-blue',
				increaseArea: '20%'
			});
			let wo=$("#form-member-add").validate({
				rules: {
					username: {
						required: true,
						minlength: 2,
						maxlength: 16
					},
					sex: {
						required: true,
					},
					phone: {
						required: true,
						isMobile: true,
					},
					email: {
						required: true,
						email: true,
					},
				},
				submitHandler:function(form) {
					$("input[type=\"submit\"]").addClass('disabled').attr("disabled",true);
					var index = layer.load(1, {
						shade: [0.1,'#fff'] //0.1透明度的白色背景
					});
					setTimeout(()=>{
						$("input[type=\"submit\"]").removeClass('disabled').attr("disabled",false);
						layer.close(index);
					},1000)
					form.submit();
				}
			});
		});
	</script>
</body>
</html>
